package week05;

import java.util.Random;

public class TestProxy {
    public static void main(String args[]) {
        Flash flash = new Flash();
        Graphic graphic = new Graphic();
        Media media = new Media();

        flashProxy flashProxy = new flashProxy(flash);
        graphicProxy graphicProxy = new graphicProxy(graphic);
        mediaProxy mediaProxy = new mediaProxy(media);

        Random random = new Random();
        Boolean b = random.nextBoolean();

        if (b) {
            flashProxy.draw();
            graphicProxy.draw();
            mediaProxy.draw();
        } else {
            System.out.println("something wrong");
        }

    }
}
